package com.jingdianjichi.subject.application.mq;

import lombok.extern.slf4j.Slf4j;
import org.apache.rocketmq.spring.annotation.RocketMQMessageListener;
import org.apache.rocketmq.spring.core.RocketMQListener;
import org.springframework.stereotype.Component;

/**
 * Description:
 *
 * @Author dal
 * @Create 2024/7/4 17:16
 */
@Component
@RocketMQMessageListener(topic = "first-topic", consumerGroup = "test-group")
@Slf4j
public class testConsumer implements RocketMQListener<String> {

    @Override
    public void onMessage(String s) {
        log.info("接收到消息mq：{}", s);
    }
}
